﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using CommonEntity.CommonImageEntities;
using ImageDomain.DE;
using OpenCvSharp;
using Point3d = CommonEntity.CommonImageEntities.Point3d;

namespace ImageDomain.Agg;
public interface IArmBoneSegAgg
{
    public Dictionary<SegToolsEnum, IList<Point3d>> SegMarks { get; }

    public IMaskImage3d? LablesImage3d { get; set; }

    public IMaskImage3d? UlnaImage3d { get; }
    public IMaskImage3d? RadiusImage3d { get; }
    public IMaskImage3d? TfccImage3d { get; }

    public IImage3d? CtImage { get; }

    public Task BuildMaskByAxMat(Dictionary<int, Mat> matDic);
    public Task BuildMaskBySagMat(Dictionary<int, Mat> matDic);
    public Task BuildMaskByCorMat(Dictionary<int, Mat> matDic);

    /// <summary>
    /// 加载分割的图像
    /// </summary>
    /// <param name="file"></param>
    /// <param name="segEnum"></param>
    /// <returns></returns>
    public Task<bool> LoadLabelsImage(string file);

    /// <summary>
    /// 加载原图像
    /// </summary>
    /// <param name="file"></param>
    /// <returns></returns>
    public Task LoadOriginImage(string file);

    /// <summary>
    /// 加载图像序列
    /// </summary>
    /// <param name="dcms"></param>
    /// <returns></returns>
    public Task LoadOriginImage(IList<string> dcms);

    /// <summary>
    /// 根据目录加载图像
    /// </summary>
    /// <param name="dir"></param>
    /// <returns></returns>
    public Task LoadOriginImageByDir(string dir);


    public Task SetSegMaskImage(byte[][][] image_array);

    public Task SaveDataToHistory();

}
